package com.baidu.model;

import java.util.List;

import com.jfinal.plugin.activerecord.Model;
public class Dept extends Model<Dept>{
	
	private static final long serialVersionUID = 282908528936842633L;
	
	public static final Dept dao = new Dept();
	
	private List<Dept> children;

	public List<Dept> getChildren() {
		return children;
	}

	public void setChildren(List<Dept> children) {
		this.children = children;
	}

	public List<Dept> getDeptByPid(Integer pid) {
		return Dept.dao.find("from dept where isDeleted=false and pid=" + pid);
	}
	
}
